<template>


    <el-form size="mini" label-width="100px">

        <el-form-item :label="value.name">

            <el-input v-if="value.type=='input' " v-model="value.value"></el-input>

            <el-radio-group v-if="value.type == 'radio'" v-model="value.value">

                <el-radio-button v-for="radio_item in value.source" :label="radio_item.key">
                    {{radio_item.value}}
                </el-radio-button>
            </el-radio-group>

            <el-color-picker v-model="value.value"  v-if="value.type=='color'" ></el-color-picker>

            <el-input-number v-model="value.value" :min="value.min"

                             v-if="value.type == 'number' "
                             :max="value.max"></el-input-number>


            <PropesEditComponent v-for="(item_l2 ,index) in value.items"  v-model="value.items[index]"></PropesEditComponent>



        </el-form-item>


    </el-form>

</template>

<script>
    export default {

        name: 'PropesEditComponent',

        props: {

            value: {
                type: Object,
                default: () => {
                    return {"type": ""};
                }
            }
        }
    }
</script>

<style scoped>

</style>